package xin.marcher.module.diplomacy.api;

import xin.marcher.module.common.core.JsonResult;
import xin.marcher.module.diplomacy.domain.dto.CompletionSearchWordsDTO;
import xin.marcher.module.diplomacy.domain.dto.HistorySearchWordDTO;
import xin.marcher.module.diplomacy.domain.dto.HistorySearchWordResultDTO;
import xin.marcher.module.diplomacy.domain.dto.PorductSearchDTO;
import xin.marcher.module.diplomacy.domain.query.*;

/**
 * 商品搜索
 */
public interface ProductSearchApi {

    /**
     * 保存历史搜索词接口
     */
    JsonResult<HistorySearchWordResultDTO> saveHistorySearchWord(HistorySearchWordRequest request);

    /**
     * 查询历史搜索词接口
     */
    JsonResult<HistorySearchWordDTO> listHistorySearchWords(HistorySearchWordQuery request);

    /**
     * 搜索词补全接口
     */
    JsonResult<CompletionSearchWordsDTO> listCompletionSearchWords(CompletionSearchWordQuery request);

    /**
     * 商品搜索接口
     */
    JsonResult<PorductSearchDTO> searchProducts(ProductSearchQuery request);

    /**
     * 商品结构化查询接口
     */
    JsonResult<PorductSearchDTO> structuredSearchProducts(ProductStructuredQuery request);
}
